package config

import (
	"github.com/cloudwego/hertz/pkg/app/server"
	"github.com/cloudwego/hertz/pkg/network/netpoll"
)

func NewHttp(addr string) *server.Hertz {
	h := server.Default(
		server.WithAltTransport(netpoll.NewTransporter),
		server.WithHostPorts(addr),
	)
	return h
}
